const express = require('express');

const adminController = require('../controllers/admin');

const router = express.Router();

// admin/product-list
router.get('/product-list', adminController.getProductList);

// /admin/add-product
router.get('/add-product', adminController.getEditProduct);

// admin/edit-product
router.get('/edit-product/:prodId', adminController.getEditProduct);

// admin/edit-product
router.post('/edit-product', adminController.postEditProduct);

// admin/delete-product
router.post('/delete-product', adminController.postDeleteProduct);

module.exports = router;